package console.manager;

import gnu.expr.ModuleMethod;
import console.ConsoleAction;

public class ScmTaskProcess implements TaskProcess {
	ModuleMethod method;
  console.ConsoleAction consoleAction;
	public ScmTaskProcess(ModuleMethod method,ConsoleAction consoleAction) {
		this.method=method;
    this.consoleAction=consoleAction;
	}
	public void start(int taskId) throws Exception {
		try {
			method.apply2(taskId,consoleAction);
		} catch (Throwable e) {
			throw new Exception(e.getMessage(),e);
		}
	}
}
